#pragma once
#include "DataCapture.hxx"
#include "AppSetting.hxx"

class ChannelYUVCapture
{
public:
	ChannelYUVCapture(void);
	~ChannelYUVCapture(void);
	int CreateReadYUVThread();
	int StopYUVFileCapture();

	inline BOOL IsReadFrameThreadEnd() { return _bReadFrameThreadEnd; }

	inline DataCapture* getDataCapture() { return _dataCapture; }
	inline void setDataCapture( DataCapture* capture ) { _dataCapture = capture; }

	inline void SetChannelId( int id ) { _iChannelId = id; }
	inline int GetChannelId() { return _iChannelId; }

	inline void SetDispWnd( HWND wnd ) { _dispWnd = wnd; }

	inline char* getFileName(int channelId){return _fileName[channelId];}
	void setDirFileName(char* filename,int id);

private:
	HWND	_dispWnd;
	int _iChannelId;
	char _fileName[3][256];
	char* frameBuf;

	HANDLE _hReadFrameThread;
	BOOL _bReadFrameThreadEnd;

	DataCapture* _dataCapture;
};

